package kr.hkit.androidcomplete02.ch12;

import java.util.ArrayList;

import kr.hkit.androidcomplete02.R;
import android.app.ListActivity;
import android.os.Bundle;

public class ListActivityEx02 extends ListActivity {
	ArrayList<MyMenu> arLists;

	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);

		arLists = new ArrayList<>();
		arLists.add(new MyMenu(R.drawable.airplane, "비행기"));
		arLists.add(new MyMenu(R.drawable.toycar, "자동차"));
		arLists.add(new MyMenu(R.drawable.ic_launcher, "안드로이드 보이"));
		
		MyCustomAdapter adapter = new MyCustomAdapter(this, R.layout.ch12_icontext, arLists);
		
		setListAdapter(adapter);
	}
}
